// NspireIO Translation Layer
// niotl_: NspireIO Translation Layer

#include <nspireio2.h>

// This should be set!
void nio_EnableDrawing(nio_console* c, BOOL drawing_enabled);

// Create a pointer to a NspireIO Console
nio_console* nio_console_ptr;

// printf displays text via format
int niotl_printf(const char *format, ...);
	void nio_printf(nio_console* c, char *format, ...);

// getchar returns the next character from stdin
int niotl_getchar(void);
	char nio_getch(void)
	char nio_GetChar(nio_console* c);

// gets returns a string, reads characters until EOF or '\n' newline is reached
char* niotl_gets(char* str);
	int nio_GetStr(nio_console* c, char* str);

// putchar - print one character
int niotl_putchar(int character);
	void nio_PrintChar(nio_console* c, char ch);

// puts - writes C string (pointed to by str) and appends a newline character
// '\n'
// Writes the C string until it hits NULL '\0', '\0' is never printed
int niotl_puts(const char* str);
	void nio_PrintStr(nio_console* c, char* str);

// vprintf - Writes to stdout the contents of the format string, expanding the
// format tags with the value of the argument list arg. This function behaves
// exactly as printf except that the variable argument list is passed as a
// va_list instead of a succession of arguments, which becomes specially useful
// when the argument list to be passed comes itself from a variable argument
// list in the calling function. vprintf does not automatically call the va_end
// macro.
int niotl_vprintf(const char* format, va_list arg);

// scanf -
// Reads data from stdin and stores them according to the parameter format into
// the locations pointed by the additional arguments. The additional arguments
// should point to already allocated objects of the type specified by their
// corresponding format tag within the format string.
int niotl_scanf(const char* format, ...);

// fprintf
